<?php

/*********************门店*********************/
//门店列表
Route::get('get-shop-list', ['as' => 'get_shop_list', 'uses' => 'ShopController@get_shop_list']);
//门店详情
Route::get('get-shop-info', ['as' => 'get_shop_info', 'uses' => 'ShopController@get_shop_info']);
//获取所有维修店服务商品（按距离等条件筛选）
Route::get('get-all-shop-repair-goods', ['as' => 'get_all_shop_repair_goods', 'uses' => 'ShopController@get_all_shop_repair_goods']);
Route::get('get-repair-type', ['as' => 'get_repair_type', 'uses' => 'ShopController@get_repair_type']);


//门店保养套餐
Route::get('get-shop-maintain', ['as' => 'get_shop_maintain', 'uses' => 'MaintainShopController@shop_maintain_list']);
//获取门店服务商品列表
Route::get('get-repair-goods-list', ['as' => 'get_repair_goods_list', 'uses' => 'MaintainShopController@get_repair_goods_list']);
//获取门店服务商品列表
Route::get('get-repair-goods-detail', ['as' => 'get_repair_goods_detail', 'uses' => 'MaintainShopController@get_repair_goods_detail']);


/*********************商城模块-商品列表*********************/
//搜索联想
Route::get('suggest-list', ['as' => 'suggest_list', 'uses' => 'GoodsController@suggest_list']);
//商品搜索
Route::get('search-goods-list', ['as' => 'search_goods_list', 'uses' => 'GoodsController@search_goods_list']);
//获取热门搜索
Route::get('hot-search-title', ['as' => 'hot_search_title', 'uses' => 'GoodsController@hot_search_title']);
//获取搜索标签
Route::get('search-goods-tag', ['as' => 'search_goods_tag', 'uses' => 'GoodsController@search_goods_tag']);

//分类商品列表
Route::get('get-cate-goods-list', ['as' => 'get_cate_goods_list', 'uses' => 'GoodsController@get_cate_goods_list']);
//获取指定分类下的商品列表
Route::get('get-cate-goods-more', ['as' => 'get_cate_goods_more', 'uses' => 'GoodsController@get_cate_goods_more']);
//获取商品详情
Route::get('get-goods-info', ['as' => 'get_goods_info', 'uses' => 'GoodsController@get_goods_info']);
//获取商品规格属性
Route::get('get-goods-product', ['as' => 'get_goods_product', 'uses' => 'GoodsController@get_goods_product']);
//个人中心获取推荐商品列表
Route::get('recommend-goods-list', ['as' => 'recommend_goods_list', 'uses' => 'GoodsController@recommend_goods_list']);

//获取快递公司列表
Route::get('get-express-list', ['as' => 'get_express_list', 'uses' => 'PublicController@get_express_list']);
//物流追踪
Route::get('logistics-tracking', ['as' => 'logistics_tracking', 'uses' => 'PublicController@logistics_tracking']);
//获取取消订单，申请退款原因(标签)
Route::get('cancel-order-label', ['as' => 'cancel_order_label', 'uses' => 'PublicController@cancel_order_label']);

/**需要验证登录token的路由 start  **/
Route::group(['middleware' => ['api_auth:api']], function () {

    /*********************门店*********************/
    //门店保养套餐预生成订单
    Route::post('shop-order-preview', ['as' => 'shop_order_preview', 'uses' => 'MaintainShopController@order_preview']);
    //门店保养套餐生成订单（创建订单）
    Route::post('generate-maintain-order', ['as' => 'generate_maintain_order', 'uses' => 'MaintainShopController@generate_maintain_order']);

    //门店服务商品预生成订单
    Route::post('shop-repair-order-preview', ['as' => 'shop_repair_order_preview', 'uses' => 'MaintainShopController@repair_order_preview']);
    //门店服务商品生成订单（创建订单）
    Route::post('generate-repair-order', ['as' => 'generate_repair_order', 'uses' => 'MaintainShopController@generate_repair_order']);

    //支付订单
    Route::post('repair-pay-order', ['as' => 'repair_pay_order', 'uses' => 'MaintainShopController@repair_pay_order']);
    //获取订单列表
    Route::get('get-repair-store-order', ['as' => 'get_repair_store_order', 'uses' => 'MaintainShopController@get_repair_store_order']);
    //获取订单详情
    Route::get('get-repair-store-order-info', ['as' => 'get_repair_store_order_info', 'uses' => 'MaintainShopController@get_repair_store_order_info']);
    //订单操作（取消订单，申请退款）
    Route::post('handle-repair-order', ['as' => 'handle_repair_order', 'uses' => 'MaintainShopController@handle_repair_order']);
    //获取售后订单列表
    Route::get('get-repair-sale-order', ['as' => 'get_repair_sale_order', 'uses' => 'MaintainShopController@get_sale_order']);
    //删除订单
    Route::get('del-repair-order', ['as' => 'del_repair_order', 'uses' => 'MaintainShopController@del_order']);


    /*********************商城模块-购物车*********************/
    //添加商品到购物车
    Route::post('add-to-car', ['as' => 'add_to_car', 'uses' => 'StoreCarController@add_to_car']);
    //获取购物车商品列表
    Route::get('get-to-car-list', ['as' => 'get_to_car_list', 'uses' => 'StoreCarController@get_to_car_list']);
    //删除购物车中的商品
    Route::post('del-car-goods', ['as' => 'del_car_goods', 'uses' => 'StoreCarController@delete']);
    //加减购物车中商品数量
    Route::post('change-car-goods-num', ['as' => 'change_car_goods_num', 'uses' => 'StoreCarController@change_num']);
    //修改购物车中商品规格
    Route::post('change-car-goods-product', ['as' => 'change_car_goods_product', 'uses' => 'StoreCarController@change_product']);

    /*********************商城模块-普通订单（活动订单）*********************/
    //结算台--预生成订单(详情->立即购买)
    Route::post('pre-build-order', ['as' => 'pre_build_order', 'uses' => 'StoreOrderController@pre_build_order']);
    //结算台--预生成订单(购物车进入)
    Route::post('pre-build-order-by-car', ['as' => 'pre_build_order_by_car', 'uses' => 'StoreOrderController@pre_build_order_by_car']);
    //生成订单（订单创建成功后用户端唤起支付）
    Route::post('create-store-order', ['as' => 'create_store_order', 'uses' => 'StoreOrderController@create_order']);
    //支付订单
    Route::post('pay-store-order', ['as' => 'pay_store_order', 'uses' => 'StoreOrderController@pay_order']);
    //取消订单
    Route::post('cancel-store-order', ['as' => 'cancel_store_order', 'uses' => 'StoreOrderController@cancel_order']);
    //申请退款-申请退货
    Route::post('refund-store-order', ['as' => 'refund_store_order', 'uses' => 'StoreOrderController@refund_order']);
    //获取该用户的订单列表
    Route::get('get-store-order-list', ['as' => 'get_store_order_list', 'uses' => 'StoreOrderController@get_order_list']);
    //获取订单详情
    Route::get('get-store-order-info', ['as' => 'get_store_order_info', 'uses' => 'StoreOrderController@get_order_info']);
    //确认收货
    Route::post('confirm-receipt', ['as' => 'confirm_receipt', 'uses' => 'StoreOrderController@confirm_receipt']);
    //删除订单
    Route::get('del-store-order', ['as' => 'del_store_order', 'uses' => 'StoreOrderController@del_order']);
    //获取售后订单列表
    Route::get('get-general-sale-order', ['as' => 'get_general_sale_order', 'uses' => 'StoreOrderController@get_sale_order']);
    //获取售后订单详情
    Route::get('get-general-sale-order-info', ['as' => 'get_general_sale_order_info', 'uses' => 'StoreOrderController@get_sale_order_info']);
    //创建退货物流信息
    Route::post('refund-order-express', ['as' => 'refund_order_express', 'uses' => 'StoreOrderController@refund_order_express']);


    /*********************商城模块-积分订单*********************/
    //结算台--预生成积分订单
    Route::post('pre-build-order-mall', ['as' => 'pre_build_order_mall', 'uses' => 'MallOrderController@pre_build_order_mall']);
    //生成积分订单
    Route::post('create-mall-order', ['as' => 'create_mall_order', 'uses' => 'MallOrderController@create_mall_order']);
    //支付订单
    Route::post('pay-mall-order', ['as' => 'pay_mall_order', 'uses' => 'MallOrderController@pay_mall_order']);
    //获取用户订单列表
    Route::get('get-mall-order-list', ['as' => 'get_mall_order_list', 'uses' => 'MallOrderController@get_mall_order_list']);
    //获取用户订单详情
    Route::get('get-mall-order-info', ['as' => 'get_mall_order_info', 'uses' => 'MallOrderController@get_mall_order_info']);
    //获取用户确认收货
    Route::get('mall-order-take-over', ['as' => 'mall_order_take_over', 'uses' => 'MallOrderController@mall_order_take_over']);
    //取消订单
    Route::get('cancel-mall-order', ['as' => 'cancel_mall_order', 'uses' => 'MallOrderController@cancel_mall_order']);
    //删除订单
    Route::get('del-mall-order', ['as' => 'del_mall_order', 'uses' => 'MallOrderController@del_mall_order']);

});




































